package com.ibiaoke.boss.controller;

import com.ibiaoke.common.base.BaseController;
import com.ibiaoke.common.base.Page;
import com.ibiaoke.common.response.Res;
import com.ibiaoke.goods.entity.vo.MarketVo;
import com.ibiaoke.order.service.MarketService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

@Controller
public class MarketController extends BaseController{

    private Logger logger = LoggerFactory.getLogger(this.getClass().getName());

    @Autowired
    private MarketService marketService;

    @RequestMapping("/market")
    @ResponseBody
    public Res market(MarketVo marketVo, Page page){
        List<MarketVo> list =  marketService.marketList(marketVo,page);
        return new Res().addResponse("list",list);
    }

}
